//
//  SREvaluationWordScoreModel.m
//  KidDubbing
//
//  Created by Victor Ji on 2016/11/15.
//  Copyright © 2016年 Feizhu Tech. All rights reserved.
//

#import "SREvaluationWordScoreModel.h"

@implementation SREvaluationWordScoreModel

- (NSDictionary *)toDictionary {
    NSMutableDictionary *dic = [[NSMutableDictionary alloc] init];
    [dic setValue:self.word forKey:@"word"];
    [dic setValue:self.score forKey:@"score"];
 
    return dic;
}

+ (SREvaluationWordScoreModel *)fromDictionary:(NSDictionary *)dic {
//	if (![dic objectForKey:@"wordIndex"]) {
//		return nil;
//	}
	SREvaluationWordScoreModel *model = [[SREvaluationWordScoreModel alloc] init];
//	model.wordIndex = [[dic objectForKey:@"wordIndex"] integerValue];
	model.word = [dic objectForKey:@"word"];
	model.score = [dic objectForKey:@"score"];
	
//	NSInteger loc = [[dic objectForKey:@"rangeLocation"] integerValue];
//	NSInteger len = [[dic objectForKey:@"rangeLength"] integerValue];
//	NSRange range = NSMakeRange(loc, len);
//	model.wordRange = range;
	return model;
}

@end
